import { Component } from '@angular/core';
import { Router, RouterModule } from '@angular/router';

@Component({
  selector: 'app-dashboard',
  imports: [RouterModule],
  templateUrl: './dashboard.html',
  styleUrl: './dashboard.css'
})
export class Dashboard {
  constructor(private router: Router) {}

  logout() {
    // 这里应该调用认证服务的登出方法
    // 目前仅作演示，直接跳转到登录页
    this.router.navigate(['/login']);
  }
}